Skip to content

Make deployment kill-timeout configurable via env var#423

Merged
ppXD merged 1 commit into
mainfrom
fix/configurable-deployment-timeout
Jun 10, 2026
Merged

Make deployment kill-timeout configurable via env var#423
ppXD merged 1 commit into
mainfrom
fix/configurable-deployment-timeout

Conversation

@ppXD

@ppXD ppXD commented Jun 10, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • The 60-minute deployment kill-timer in DeploymentPipelineRunner was a hardcoded internal init constant with no operator override — any deployment legitimately exceeding 60 minutes (large DB migrations, multi-stage rollouts) was force-cancelled with no escape hatch.
  • Add SQUID_DEPLOYMENT_TIMEOUT_MINUTES following the established HalibutPollingWorkAdmission.ParseMaxPendingWorkPerAgent pattern: a pure static parser (ParseDeploymentTimeout) with a safe fallback to the 60-minute default on blank / invalid / non-positive input, plus a thin env reader wired into the property's default initializer.
  • Non-breaking: constructor signature unchanged; only additive public const / internal const / public static members. With the variable unset the effective timeout is byte-identical to the previous 60-minute behaviour.

Test plan

  • Unit: env-var name pinned (Rule 8) + default-minutes pinned
  • Unit: 11-case [Theory] over ParseDeploymentTimeout (null / empty / whitespace / valid / surrounding-whitespace / large / equal-to-default / garbage / decimal / zero / negative)
  • Unit: env-set drives effective DeploymentTimeout; env-unset falls back to 60 min (env saved/restored, isolation-safe distinct value)
  • Regression: full Services.Deployments namespace 3981/3981 green; all 4 DeploymentPipelineRunner* test classes 42/42 green
  • dotnet build src/Squid.Core — 0 errors

@ppXD ppXD added this to the 1.8.17 milestone Jun 10, 2026
The 60-minute pipeline kill-timer was a hardcoded internal-init constant
with no operator override, so any deployment legitimately exceeding 60
minutes (large DB migrations, multi-stage rollouts) was force-cancelled
with no escape hatch — a violation of the repo's own env-var override
convention.

Add SQUID_DEPLOYMENT_TIMEOUT_MINUTES following the established
ParseMaxPendingWorkPerAgent pattern: a pure static parser with a safe
fallback to the 60-minute default on blank, invalid, or non-positive
input. Leaving the variable unset preserves the historical behaviour
exactly, so the change is purely additive and non-breaking.
@ppXD
ppXD force-pushed the fix/configurable-deployment-timeout branch from 19bb19e to a3b6ec7 Compare June 10, 2026 08:02
@ppXD
ppXD merged commit 9dbde69 into main Jun 10, 2026
14 of 15 checks passed
@ppXD
ppXD deleted the fix/configurable-deployment-timeout branch June 10, 2026 08:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant